<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!-- saved from url=(0022)http://www.gaodun.com/ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="apple-itunes-app" content="app-id=591578609">

<title>德瑞姆家园</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="${csspath}/style/style.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/h_index.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/home_style.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/gkk.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/kczx.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/kczx_son.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/kszn_son.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/tab.css">
<link rel="stylesheet" type="text/css" href="${csspath}/style/index.css">
<!--[if IE 7]>
<link rel="stylesheet" href="/css/font-awesome/css/font-awesome-ie7.min.css">
<![endif]-->
<script type="text/javascript" src="${jspath}/js/m.js"></script>
<script type="text/javascript" src="${jspath}/js/gkk.js"></script>
<script type="text/javascript" src="${jspath}/js/tabs.js"></script>
<script type="text/javascript" src="${jspath}/js/jquery-1.7.1.min.js"></script>
<script type="text/javascript" src="${jspath}/js/index.js"></script>
<script>
  function ajaxGetTabContent(funcInfo,courseId){
	  jQuery.ajax({
	        url: "/course/"+funcInfo,
	        dataType: "json",
	        data: {
	            'courseId': courseId
	            
	        },
	        success: function( data ) {
	            
	            fullClassMateInfo(funcInfo,data.rows);
	        }
	    });
  }
  
  function ajaxGetPublicCourseTabInfo(contentType){
	  jQuery.ajax({
	        url: "${imgpath}/course/listRecommendCourseByType",
	        dataType: "json",
	        data: {
	            'typeName': contentType,
	            'rows':16,
	            'page':0
	        },
	        success: function( data ) {
	        	jQuery("#public_course_list").html("");
	        	//alert(data);
	        	fullPublicCourseInfo(data.rows);
	        },
	        error: function(){
                //alert('123');
            } 
	    });
	  
  }
  
  function fullPublicCourseInfo(data){
	  //清除显示部分的原有内容
	  
	  var dataInfo = "";
	  for(var i=0;i<data.length;i++){
		  if(i%4 == 0){
			  dataInfo = "<div class=\"gkk_body\">" ;
			  
		  }
		  dataInfo = dataInfo +"<div class=\"gkk_body01\"><div class=\"gkk_body02\"> <img src=\"${imgpath}/images/gkk/gkk_01.jpg\"> </div><div class=\"gkk_body03\">"+data[i].courseName+"</div><div class=\"gkk_body00\" onMouseOver=\"this.className='gkk_bodyhid'\" onMouseOut=\"this.className='gkk_body00'\" ><div class=\"gkk_bodyopa01\"><h2>"+data[i].courseName+"</h2><p>"+data[i].courseName+"</p></div><div class=\"gkk_bodyopa02\"> <span style=\"float:left\"> <img src=\"${imgpath}/images/gkk/bf00.png\"  align=\"absmiddle\" /> 播放：888</span> <span style=\"float:right\"> <img src=\"${imgpath}/images/gkk/pl01.png\" align=\"absmiddle\"> 评论：999</span> </div></div></div>";
	      if(i%4 == 3){
	    	  dataInfo = dataInfo+"</div>";
	      }
	  }
	  jQuery("#public_course_list").html(dataInfo);
	  
  }
  function fullClassMateInfo(funcInfo,data){
	  
	  if(funcInfo == 'courseClassmatelist'){
		  
		  jQuery("#tab5").html("");
		  var dataInfo = "";
		  dataInfo = "<div class=\"tab501\" >";
		  for(var i=0;i<data.length;i++){
			  dataInfo = dataInfo+"<div class=\"tab50101\" ><div class=\"tab5010101\" ><a href=\"#\"> <img src=\"${imgpath}/images/home_images/home_people01.jpg\"/></a> </div><div class=\"tab5010102\" ><a hrfe=\"#\"><p class=\"home_text04\" style=\"text-align:center\">"+data[i].userNickName+"</p></a></div></div><div class=\"tab50102\" ></div>";
		  }
		  dataInfo = dataInfo+"</div>";
		  jQuery("#tab5").html(dataInfo);
	  }else if(funcInfo == 'notelist'){
		  jQuery("#tab2").html("");
		  var dataInfo = "";
		  for(var i=0;i<data.length;i++){
			  dataInfo = dataInfo+"<div class=\"tab2_body\"><div class=\"tab2_body01\"><div class=\"tab2_body0101\"><div class=\"tab2_body010101\"><span style=\"color:#2884b3;\">"+data[i].noteTitle+"</span></div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"+data[i].noteContent+"</div><div class=\"tab2_body0102\"><div class=\"tab2_body010201\"><img src=\"${imgpath}/images/kczx_son/fx01.jpg\"/><br/>"+data[i].userNickName+"</div></div></div><div class=\"tab2_body02\">"+data[i].noteDate+"<a href=\"#\"><span class=\"tab2_body0201\"><img src=\"${imgpath}/images/kczx_son/zan.png\"/>&nbsp;&nbsp;赞（"+data[i].likeNum+"）</span></a></div></div>"; 
		  }
		  jQuery("#tab2").html(dataInfo);
	  }else if(funcInfo == 'courseJieShao'){
		  jQuery("#tab4").html("");
		  var dataInfo = "";
		  if(data.length>0){
			  dataInfo = data[0].courseDetail;
		  }
		  jQuery("#tab4").html(dataInfo);
	  }else if(funcInfo == 'commentlist'){
		  jQuery("#tab3").html("");
		  var dataInfo = "";
		  var allComment = "";//所有评论
		  var goodComment = "";//好评
		  var normalComment = "";//中评
		  var badComment = "";//差评
		  dataInfo = "<div class=\"tab303\"> <a href=\"#\" onMouseDown=\"tab300(1,5);\"><div id=\"tab0301\" class=\"tab30301\"> 全部 </div></a> <a  href=\"#\" onMouseDown=\"tab300(2,5);\" ><div id=\"tab0302\" class=\"tab30301\" style=\"background-color:#E2EFFC;border:1px solid #E2EFFC\"> 好评 </div></a><a href=\"#\" onMouseDown=\"tab300(3,5);\"><div id=\"tab0303\" class=\"tab30301\" style=\"background-color:#E2EFFC;border:1px solid #E2EFFC\"> 中评 </div></a> <a href=\"#\" onMouseDown=\"tab300(4,5);\"><div id=\"tab0304\" class=\"tab30301\" style=\"background-color:#E2EFFC;border:1px solid #E2EFFC\"> 差评 </div></a></div> ";
		  allComment = "<div id=\"tab3001\" class=\"tab300\">";
		  goodComment = "<div id=\"tab3002\" class=\"tab300\" style=\"display:none\">";
		  normalComment = "<div id=\"tab3003\" class=\"tab300\" style=\"display:none\">";
		  badComment = "<div id=\"tab3004\" class=\"tab300\" style=\"display:none\">";
		  for(var i=0;i<data.length;i++){
			  allComment = allComment +"<div class=\"tab30001\"><div class=\"tab30002\"> <img src=\"${imgpath}/images/kczx_son/user02.jpg\"> </div><div class=\"tab30003\"><div class=\"tab3040102\"><div class=\"tab3040103\"><a href=\"#\"><span class=\"retext05\">"+data[i].nickName+"</span></a>给课程打了5分 </div><div class=\"tab3040104\"> "+data[i].commentContent+" </div><div class=\"tab3040105\"> 2014/8/18&nbsp;11:40:40 </div></div></div></div>";
			  if(data[i].commentType == 1){
				  goodComment = goodComment+"<div class=\"tab30001\"><div class=\"tab30002\"> <img src=\"${imgpath}/images/kczx_son/user02.jpg\"> </div><div class=\"tab30003\"><div class=\"tab3040102\"><div class=\"tab3040103\"><a href=\"#\"><span class=\"retext05\">"+data[i].nickName+"</span></a>给课程打了5分 </div><div class=\"tab3040104\"> "+data[i].commentContent+" </div><div class=\"tab3040105\"> 2014/8/18&nbsp;11:40:40 </div></div></div></div>";
			  }else if(data[i].commentType == 2){
				  normalComment = normalComment+"<div class=\"tab30001\"><div class=\"tab30002\"> <img src=\"${imgpath}/images/kczx_son/user02.jpg\"> </div><div class=\"tab30003\"><div class=\"tab3040102\"><div class=\"tab3040103\"><a href=\"#\"><span class=\"retext05\">"+data[i].nickName+"</span></a>给课程打了5分 </div><div class=\"tab3040104\"> "+data[i].commentContent+" </div><div class=\"tab3040105\"> 2014/8/18&nbsp;11:40:40 </div></div></div></div>";
			  }else if(data[i].commentType == 3){
				  badComment = badComment+"<div class=\"tab30001\"><div class=\"tab30002\"> <img src=\"${imgpath}/images/kczx_son/user02.jpg\"> </div><div class=\"tab30003\"><div class=\"tab3040102\"><div class=\"tab3040103\"><a href=\"#\"><span class=\"retext05\">"+data[i].nickName+"</span></a>给课程打了5分 </div><div class=\"tab3040104\"> "+data[i].commentContent+" </div><div class=\"tab3040105\"> 2014/8/18&nbsp;11:40:40 </div></div></div></div>";
			  }
		  }
		  allComment = allComment+"</div>";
		  goodComment = goodComment+"</div>";
		  normalComment = normalComment+"</div>";
		  badComment = badComment+"</div>";
		  jQuery("#tab3").html(dataInfo+allComment+goodComment+normalComment+badComment);
	  }else if(funcInfo == 'keshilist'){
		  jQuery("#tab1").html("");
		  var dataInfo = "";
		  dataInfo = "<div class=\"tab1_body00\">";
		  for(var i=0;i<data.length;i++){
			  var temp = "";
			  if(i%3 == 0){
				  temp = "<div class=\"tab1_body010201\"> </div>";
			  }else if(i%3 == 1){
				  temp = " <div class=\"tab1_body010202\"> </div>";
			  }else if(i%3 ==2){
				  temp = "<div class=\"tab1_body010203\"> </div>";
			  }
			  dataInfo = dataInfo+"<div class=\"tab1_body01\"><div class=\"tab1_body0101\">"+((i%3)==0?"课时1":"")+"</div><div class=\"tab1_body0102\">"+temp+"</div><a href=\"#\"  class=\"tab1_body0103\" onMouseOver=\"this.className='tab1_body0103201'\" onMouseOut=\"this.className='tab1_body0103'\" onClick=\"clic();\"><div id=\"col1\"><div id=\"col011\"> </div>"+data[i].keShiTitle+"</div></a></div>";
		  }
		  dataInfo = dataInfo+"</div>";
		  jQuery("#tab1").html(dataInfo);
	  }
	  
  }
</script>

<style type="text/css">
li {
	list-style-type:none;
}
a {
	color:#111;
	text-decoration:none;
}
a:hover {
	color:#333;
	text-decoration:none;
}
</style>
</head>

<body style="align:center overflow-x:hidden;">
 
   <%@include   file="./header_menu.jsp" %>
   

</body>